#include "stdio.h"
#include "func.h"
void stu_menu(Class * P,int location )
{
    int func = 0;   // 菜单页面功能选择
    int sign = 0;   // 退出按钮
    int sign_1 = 0; // 退出whilea
    while (1)
    {
        system("clear");
        printf("****************************\n");
        printf("*[查看成绩]        (1)    *\n");
        printf("*[修改密码]        (2)    *\n");
        printf("*退出请按          (-1)    *\n");
        printf("****************************\n");
        printf("请选择您要使用的功能:");
        scanf("%d", &func);
        system("clear");
        switch (func)
        {
        case 1:
            printf("[查看成绩]:\n");
            Check_score(P);
            printf("退出请按(-1)");
            scanf("%d", &sign);
            if (sign == -1)
            {
                system("clear");
                break;
            }

            case 2:
            printf("[修改密码]:\n");
            Change_Pas(P,location);
            printf("退出请按(-1)");
            scanf("%d", &sign);
            if (sign == -1)
            {
                system("clear");
                break;
            }

        case -1:
            sign_1 = -1;
            break;

        default:
            break;
        }
        if (sign_1 == -1)
        {
            // system("clear");
            break;
        }
    }
}